package com.cy.Service;

import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;
import org.springframework.web.client.RestTemplate;

@Service
public class PayServiceImpl implements PayService {
    @Autowired
    RestTemplate restTemplate;
    @Override
    public String pay(String orderID) {

        //数据库操作mybatis
        //处理支付，返回结果给orderSystem
        //使用ribben里面的工具类
        //url
        String result = restTemplate.getForObject("http://43.143.77.47:8848/service-order/hello?orderID="+orderID,String.class);
        //调用service
        return result;
    }
}
